<template>
  <div>
    <van-divider v-if="align" :dashed="dashed" :content-position="align">{{label}}</van-divider>
    <van-divider v-else :dashed="dashed">{{label}}</van-divider>
  </div>
</template>

<script>
import { Divider } from 'vant'
import common from './item'
export default {
  mixins: [common],
  components: {
    vanDivider: Divider
  },
  computed: {
    // 对齐方式：left|right
    align () {
      return this.info.align
    },
    // 分割线是否为虚线
    dashed () {
      return this.info.dashed || false
    }
  }
}
</script>
